	.file	"compress.c"
	.section	.rodata
	.align 32
.LC0:
	.string	"usage : %s <infile> <outfile>\n"
.LC1:
	.string	"-"
.LC2:
	.string	"r"
	.align 32
.LC3:
	.string	"compress : error opening input file"
	.align 32
.LC4:
	.string	"compress : error opening output file"
	.text
.globl main
	.type	main, @function
main:
	pushl	%ebp
	movl	%esp, %ebp
	subl	$24, %esp
	andl	$-16, %esp
	movl	$0, %eax
	subl	%eax, %esp
	cmpl	$3, 8(%ebp)
	je	.L9
	subl	$4, %esp
	movl	12(%ebp), %eax
	pushl	(%eax)
	pushl	$.LC0
	pushl	stderr
	call	fprintf
	addl	$16, %esp
	subl	$12, %esp
	pushl	$1
	call	exit
.L9:
	movl	12(%ebp), %eax
	addl	$4, %eax
	subl	$4, %esp
	pushl	$2
	pushl	$.LC1
	pushl	(%eax)
	call	strncmp
	addl	$16, %esp
	testl	%eax, %eax
	jne	.L10
	movl	stdin, %eax
	movl	%eax, -8(%ebp)
	jmp	.L11
.L10:
	subl	$8, %esp
	pushl	$.LC2
	movl	12(%ebp), %eax
	addl	$4, %eax
	pushl	(%eax)
	call	fopen
	addl	$16, %esp
	movl	%eax, -8(%ebp)
	cmpl	$0, -8(%ebp)
	jne	.L11
	subl	$12, %esp
	pushl	$.LC3
	call	perror
	addl	$16, %esp
	subl	$12, %esp
	pushl	$1
	call	exit
.L11:
	movl	12(%ebp), %eax
	addl	$8, %eax
	subl	$4, %esp
	pushl	$2
	pushl	$.LC1
	pushl	(%eax)
	call	strncmp
	addl	$16, %esp
	testl	%eax, %eax
	jne	.L13
	subl	$12, %esp
	pushl	$1
	call	bf_stream_new
	addl	$16, %esp
	movl	%eax, -12(%ebp)
	cmpl	$0, -12(%ebp)
	jne	.L15
	subl	$12, %esp
	pushl	$.LC4
	call	perror
	addl	$16, %esp
	subl	$12, %esp
	pushl	$1
	call	exit
.L13:
	subl	$8, %esp
	pushl	$577
	movl	12(%ebp), %eax
	addl	$8, %eax
	pushl	(%eax)
	call	bf_open
	addl	$16, %esp
	movl	%eax, -12(%ebp)
	cmpl	$0, -12(%ebp)
	jne	.L15
	subl	$12, %esp
	pushl	$.LC4
	call	perror
	addl	$16, %esp
	subl	$12, %esp
	pushl	$1
	call	exit
.L15:
	subl	$12, %esp
	pushl	-8(%ebp)
	call	fgetc
	addl	$16, %esp
	movl	%eax, -4(%ebp)
	subl	$12, %esp
	pushl	-4(%ebp)
	call	huff_tree_init
	addl	$16, %esp
	subl	$8, %esp
	pushl	-4(%ebp)
	pushl	-12(%ebp)
	call	bf_putchar
	addl	$16, %esp
.L17:
	subl	$12, %esp
	pushl	-8(%ebp)
	call	fgetc
	addl	$16, %esp
	movl	%eax, -4(%ebp)
	cmpl	$-1, -4(%ebp)
	jne	.L19
	jmp	.L18
.L19:
	subl	$8, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	pushl	-4(%ebp)
	call	huff_getcode
	addl	$16, %esp
	testl	%eax, %eax
	je	.L20
	subl	$8, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	pushl	-12(%ebp)
	call	huff_putcode
	addl	$16, %esp
	jmp	.L21
.L20:
	subl	$12, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	call	huff_special_code
	addl	$16, %esp
	subl	$8, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	pushl	-12(%ebp)
	call	huff_putcode
	addl	$16, %esp
	subl	$8, %esp
	pushl	-4(%ebp)
	pushl	-12(%ebp)
	call	bf_putchar
	addl	$16, %esp
.L21:
	subl	$12, %esp
	pushl	-4(%ebp)
	call	huff_tree_modify
	addl	$16, %esp
	jmp	.L17
.L18:
	subl	$12, %esp
	pushl	-12(%ebp)
	call	bf_isaligned
	addl	$16, %esp
	testl	%eax, %eax
	jne	.L22
	subl	$12, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	call	huff_special_code
	addl	$16, %esp
	subl	$8, %esp
	leal	-24(%ebp), %eax
	pushl	%eax
	pushl	-12(%ebp)
	call	huff_putcode
	addl	$16, %esp
	subl	$12, %esp
	pushl	-12(%ebp)
	call	bf_align
	addl	$16, %esp
.L22:
	subl	$12, %esp
	pushl	-12(%ebp)
	call	bf_close
	addl	$16, %esp
	subl	$12, %esp
	pushl	-8(%ebp)
	call	fclose
	addl	$16, %esp
	movl	$0, %eax
	leave
	ret
	.size	main, .-main
	.section	.note.GNU-stack,"",@progbits
	.ident	"GCC: (GNU) 3.3.2 20031022 (Red Hat Linux 3.3.2-1)"
